[PATCH] [WebAssembly] Use default attributes for intrinsics
authorNikita Popov <npopov@redhat.com>
Mon, 7 Nov 2022 14:50:05 +0000 (15:50 +0100)
committerGianfranco Costamagna <locutusofborg@debian.org>
Sat, 4 May 2024 05:18:23 +0000 (07:18 +0200)
commit8fc26e418985c066d5c13a383b3fb5bd4f293776
tree114796fd212c1175404241f604e5d0fa7aedfe32
parente805c21db690c56bf7ad808652c06c14201d092e
[PATCH] [WebAssembly] Use default attributes for intrinsics

This switches wasm intrinsics to use default attributes,
i.e. nofree, nosync, nocallback and willreturn. Especially
willreturn will be required to avoid optimization regressions
in the future.

The attributes are omitted from the trapping fptoi intrinsics
(where I assume trapping is considered well-defined, and as such
these aren't willreturn), the throw/rethrow intrinsics (which
will unwind) and the atomic intrinsics (which aren't nosync).

Differential Revision: https://reviews.llvm.org/D137551

Gbp-Pq: Name CVE-2023-29932.patch
llvm/include/llvm/IR/IntrinsicsWebAssembly.td
llvm/test/CodeGen/WebAssembly/lower-wasm-ehsjlj.ll